﻿<!DOCTYPE html>
<html>
  <head>
    <title>Grubyware</title>
    <%= stylesheet_link_tag 'reset.css' %>
    <%= stylesheet_link_tag 'form.css' %>
    <%= stylesheet_link_tag 'grubyware.css' %>
    <%= javascript_include_tag :defaults %>
    <%= csrf_meta_tag %>
  </head>
  <body>

    <div id="gru-wrapper">

      <div id="gru-header">

        <%= link_to image_tag("grubyware_header.png", :alt => "Grubyware Header", :class => "round"), root_path %>

        <div id="gru-login-menu">
          <% if user_signed_in? %>
            Angemeldet als: <span id="gru-login-menu-user"><%= current_user.alias %></span> &middot;
            <%= link_to (t :logout, :scope => [:helpers, :navigation, :application]), destroy_user_session_path %>
          <% else %>
            <%= link_to (t :register, :scope => [:helpers, :navigation, :application]), new_user_registration_path %> oder <%= link_to (t :login, :scope => [:helpers, :navigation, :application]), new_user_session_path %>
          <% end %>
        </div> <!-- gru-login-menu end -->
      </div> <!-- gru-header end -->

      <div id="gru-main">
        <% if params[:project_id] || params[:id] %>
          <!-- the project menu -->
          <%= render :partial => "layouts/menu" %>
        <% end %>

        <div id="gru-main-content">

          <%= yield %>

        </div><!-- gru-main-content end -->

        <% if flash[:notice] %>
          <p class="gru-notice"><%= flash[:notice] %></p>
        <% end %>
        <% if flash[:error] %>
          <p class="gru-error"><%= flash[:error] %></p>
        <% end %>

      </div> <!-- gru-main end -->

      <div id="gru-footer">
        <%= link_to image_tag("grubyware_footer.png", :alt => "Grubyware Footer", :class => "round"), "http://code.google.com/p/grubyware", :target => "_blank" %>
      </div> <!-- gru-footer end -->

    </div> <!-- gru-wrapper end -->

  </body>
</html>
